package com.hkbigdata.datagovernance.ds.service.impl;

import com.baomidou.dynamic.datasource.annotation.DS;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.hkbigdata.datagovernance.ds.bean.TDsTaskInstance;
import com.hkbigdata.datagovernance.ds.mapper.TDsTaskInstanceMapper;
import com.hkbigdata.datagovernance.ds.service.TDsTaskInstanceService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author 
 * @since 2024-01-11
 */
@Service
@DS("ds")
public class TDsTaskInstanceServiceImpl extends ServiceImpl<TDsTaskInstanceMapper, TDsTaskInstance> implements TDsTaskInstanceService {

    @Override
    public List<TDsTaskInstance> getTdsTaskInstanceByAssessDate(String assessDate) {
        List<TDsTaskInstance> tDsTaskInstances = list(new QueryWrapper<TDsTaskInstance>().eq("date_format(start_time,'%Y-%m-%d')", assessDate));
        return tDsTaskInstances;
    }
}
